agents
Class UIAgentExtended
java.lang.Object
negotiator.Agent
agents.UIAgentExtended
public class UIAgentExtended
- extends Agent
- Author:
- W.Pasman, modified version of Dmytro's UIAgent
|
Method Summary |
Action |
chooseAction()
this function is called after ReceiveMessage,
with an Offer-action. |
Bid |
getMyPreviousBid()
|
Bid |
getOppPreviousBid()
|
static java.lang.String |
getVersion()
One agent will be kept alive over multiple sessions. |
void |
init()
This method is called by the protocol every time before starting a new
session after the internalInit method is called. |
boolean |
isUIAgent()
Determine if this agent is communicating with the user about nego steps. |
void |
ReceiveMessage(Action opponentAction)
informs you which action the opponent did |
| Methods inherited from class negotiator.Agent |
endSession, getAgentID, getName, getParameterValues, getSessionNumber, getSessionsTotal, getStrategyParameters, getUniqueIdentifier, getUtility, internalInit, loadSessionData, parseStrategyParameters, restartDataObjectsFolder, saveSessionData, setAgentID, setName, sleep |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
bidCounter
protected int bidCounter
roundData
protected agents.NegoRoundData roundData
historyOfBids
protected java.util.ArrayList<agents.NegoRoundData> historyOfBids
UIAgentExtended
public UIAgentExtended()
getVersion
public static java.lang.String getVersion()
- One agent will be kept alive over multiple sessions.
Init will be called at the start of each nego session.
init
public void init()
- Description copied from class:
Agent
- This method is called by the protocol every time before starting a new
session after the internalInit method is called. User can override this method.
- Overrides:
init in class Agent
ReceiveMessage
public void ReceiveMessage(Action opponentAction)
- Description copied from class:
Agent
- informs you which action the opponent did
- Overrides:
ReceiveMessage in class Agent
chooseAction
public Action chooseAction()
- Description copied from class:
Agent
- this function is called after ReceiveMessage,
with an Offer-action.
- Specified by:
chooseAction in class Agent
- Returns:
- (should return) the bid-action the agent wants to make.
isUIAgent
public boolean isUIAgent()
- Description copied from class:
Agent
- Determine if this agent is communicating with the user about nego steps.
- Overrides:
isUIAgent in class Agent
- Returns:
- true if a human user is directly communicating with the agent in order
to steer the nego. This flag is used to determine the timeout for the
negotiation (larger with human users).
getMyPreviousBid
public Bid getMyPreviousBid()
getOppPreviousBid
public Bid getOppPreviousBid()